# pip install flask_sqlalchemy
from flask_sqlalchemy import SQLAlchemy
from flask import Flask
from flask_cors import *
app = Flask(__name__)

#解决跨域
CORS(app, supports_credentials=True)

#配置当前服务的数据库参数     //root:密码@ip:port/数据库名
app.config['SQLALCHEMY_DATABASE_URI'] = "mysql+pymysql://root:root@127.0.0.1:3306/qts"
db_init =  SQLAlchemy(app)
